package com.cango.student.inter;

public class BuilderSample {
    private String header;
    private String footer;

    public static Build newBuilder() {
        return new Build();
    }

    private BuilderSample(Build build) {
        this.header = build.header;
        this.footer = build.footer;
    }

    static class Build {
        private String header;
        private String footer;

        public Build header(String header) {
            this.header = header;
            return this;
        }

        public Build footer(String footer) {
            this.footer = footer;
            return this;
        }

        public BuilderSample build() {
            return new BuilderSample(this);
        }

    }
}
